// pingjiaoView.cpp : implementation of the CPingjiaoView class
//

#include "stdafx.h"
#include "pingjiao.h"

#include "pingjiaoDoc.h"
#include "pingjiaoView.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CPingjiaoView

IMPLEMENT_DYNCREATE(CPingjiaoView, CView)

BEGIN_MESSAGE_MAP(CPingjiaoView, CView)
	//{{AFX_MSG_MAP(CPingjiaoView)
		// NOTE - the ClassWizard will add and remove mapping macros here.
		//    DO NOT EDIT what you see in these blocks of generated code!
	//}}AFX_MSG_MAP
	// Standard printing commands
	ON_COMMAND(ID_FILE_PRINT, CView::OnFilePrint)
	ON_COMMAND(ID_FILE_PRINT_DIRECT, CView::OnFilePrint)
	ON_COMMAND(ID_FILE_PRINT_PREVIEW, CView::OnFilePrintPreview)
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CPingjiaoView construction/destruction

CPingjiaoView::CPingjiaoView()
{
	// TODO: add construction code here

}

CPingjiaoView::~CPingjiaoView()
{
}

BOOL CPingjiaoView::PreCreateWindow(CREATESTRUCT& cs)
{
	// TODO: Modify the Window class or styles here by modifying
	//  the CREATESTRUCT cs

	BOOL bPreCreated = CView::PreCreateWindow(cs);
	cs.style &= ~(ES_AUTOHSCROLL|WS_HSCROLL);	// Enable word-wrapping

	return bPreCreated;
}

/////////////////////////////////////////////////////////////////////////////
// CPingjiaoView drawing

void CPingjiaoView::OnDraw(CDC* pDC)
{
	CPingjiaoDoc* pDoc = GetDocument();
	ASSERT_VALID(pDoc);
	// TODO: add draw code for native data here
}

/////////////////////////////////////////////////////////////////////////////
// CPingjiaoView printing

BOOL CPingjiaoView::OnPreparePrinting(CPrintInfo* pInfo)
{
	// default CEditView preparation
	return CView::OnPreparePrinting(pInfo);
}

void CPingjiaoView::OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo)
{
	// Default CEditView begin printing.
	CView::OnBeginPrinting(pDC, pInfo);
}

void CPingjiaoView::OnEndPrinting(CDC* pDC, CPrintInfo* pInfo)
{
	// Default CEditView end printing
	CView::OnEndPrinting(pDC, pInfo);
}

/////////////////////////////////////////////////////////////////////////////
// CPingjiaoView diagnostics

#ifdef _DEBUG
void CPingjiaoView::AssertValid() const
{
	CView::AssertValid();
}

void CPingjiaoView::Dump(CDumpContext& dc) const
{
	CView::Dump(dc);
}

CPingjiaoDoc* CPingjiaoView::GetDocument() // non-debug version is inline
{
	ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CPingjiaoDoc)));
	return (CPingjiaoDoc*)m_pDocument;
}
#endif //_DEBUG

/////////////////////////////////////////////////////////////////////////////
// CPingjiaoView message handlers
